package example.documentbased.mainModule.models.factories
{
	import example.documentbased.mainModule.models.doman.Document;
	import example.documentbased.mainModule.models.doman.Editor;
	import example.documentbased.mainModule.models.vo.DocumentVO;
	import example.documentbased.mainModule.models.vo.EditorVO;
	
	import mx.collections.ArrayList;
	import mx.utils.UIDUtil;

	public class ItemsFactory
	{
		public function createEditor(id:String, name:String, color:uint):Editor
		{
			return new Editor(id, name, color);
		}
		
		public function createEditorVO(id:String, name:String, color:uint, 
									   documents:ArrayList):EditorVO
		{
			return new EditorVO(id, name, color, documents);
		}
		
		public function createDocument(id:String, uid:String, editorId:String, 
									   name:String, text:String, lazy:Boolean = false):Document
		{
			return new Document(id, uid, editorId, name, text, lazy);
		}
		
		public function createDocumentVO(id:String, uid:String, editorId:String, 
										 name:String, text:String, lazy:Boolean = false):DocumentVO
		{
			return new DocumentVO(id, uid, editorId, name, text, lazy);
		}
	}
}